package com.zhulin.android.edoctor.fragment;

import com.zhulin.android.edoctor.MainActivity;
import com.zhulin.android.edoctor.R;

import android.app.Activity;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.widget.Button;

public class FragmentUploadSelectList extends BaseFragment implements OnClickListener{

	MainActivity mMainActivity;
	
	@Override
	public void onAttach(Activity activity) {
		super.onAttach(activity);
		mMainActivity=(MainActivity)activity;
	}
	
	@Override
	public void onCreate(Bundle savedInstanceState) {
		// TODO Auto-generated method stub
		super.onCreate(savedInstanceState);
	}
	
	@Override
	public View onCreateView(LayoutInflater inflater, ViewGroup container,
			Bundle savedInstanceState) {
		View v=inflater.inflate(R.layout.fragment_upload_listselect, container, false);
		
		v.findViewById(R.id.btnCaseType1).setOnClickListener(this);
		v.findViewById(R.id.btnCaseType2).setOnClickListener(this);
		v.findViewById(R.id.btnCaseType3).setOnClickListener(this);
		v.findViewById(R.id.btnCaseType4).setOnClickListener(this);
		v.findViewById(R.id.btnCaseType5).setOnClickListener(this);
		return v;
	}

	@Override
	public void onClick(View v) {
		switch(v.getId()){
		
		}
		String caseType=((Button)v).getText().toString();
		mMainActivity.addFragmentOfUploadCaseItemEdit(caseType);
	}	
	
	
}
